<html>
<head>
<title>Spam Teszt</a>
<style type="text/css">
#container
{
  margin: 10px auto;
  padding: 5px;
  width: 500px;
}
#container textarea,
#container input
{
  border: 1px solid #000;
  padding: 2px;
}
#container textarea
{
  height: 300px;
  width: 500px;
}
#result
{
  color: #f40000;
  font-weight: bold;
  text-align: center;
}
</style>
</head>
<body>
<div id="container">
  <form name="spammer" action="" method="post">
  <label for="text">Text:</label><br />
    <textarea name="text"><?= stripslashes($_POST['text']); ?></textarea><br />
    <input type="submit" value="Submit"/>
  </form>
  <div id="result">
  <?php
  require_once("stspam.class.php");
  if(isset($_POST['text']))
  {
    $spamCheck = new STSpam();
    switch($spamCheck->check($_POST['text']))
    {
      case -1:
        echo "notspam";
        break;
      case 0:
        echo "probably spam";
        break;
      case 1:
        echo "spam";
        break;
    }
  }
  ?>
  </div>
</div>
</body>
</html>
